package com.jake.xfeed.recyclerfeed;

import android.content.Context;

import androidx.annotation.NonNull;

public abstract class BasePagerCard<Data> extends BaseCard<Data> {
    protected boolean isPageSelected = false;

    public BasePagerCard(@NonNull Context context) {
        super(context);
    }


    public final void pageSelected() {
        isPageSelected = true;
        onPageSelected();
    }

    public final void pageUnselected() {
        isPageSelected = false;
        onPageUnselected();
    }

    public boolean isPageSelected() {
        return isPageSelected;
    }

    protected void onPageSelected() {
    }

    protected void onPageUnselected() {
    }

}